|
Keystroke programming describes a specific way of programming by which each keystroke on a device or application is recorded in some way and then played back so that the recorded key-presses can be repeated multiple times. Keystroke programming is most commonly but not exclusively found in programmable calculators, but there are keystroke-programmable software applications, too, for example Vim (text editor)〔http://vimdoc.sourceforge.net/htmldoc/repeat.html#complex-repeat〕 == Example: TI Calculators == The Texas Instruments TI-58/TI-58C/TI-59 calculators were programmable, and program storage took the form of a sequence of codes which (mostly) corresponded to the position of keys on the calculator keypad. Here is a simplified diagram of the basic key layout: Each key is assigned a two-digit code; for most (but not all) keys, the tens digit comes from the row number (as indicated down the left of the table) and the units digit comes from the column number (as indicated across the top of the table). Now consider a very simple program, which adds 2 to the number being displayed, and then stops. The program is entered starting from program location 000, and looks like this: To use this program, you would enter the number ''n'' to be operated on, press to ensure the current program location was 000, then to start execution. When the program stops (which should happen quite quickly for such a simple program), the display will be showing the number ''n'' + 2. You can see that the codes 85, 95 and 91 correspond to the positions of the keys labelled , and on the grid above, but the code for the is not 83 as you would expect from the grid position, but 02. This last code was chosen to be more easily understandable by a human trying to read the program. There is no row 0, so the codes 00 .. 09 are used to represent the keys .. . 抄文引用元・出典: フリー百科事典『 ウィキペディア(Wikipedia)』 ■ウィキペディアで「Keystroke programming」の詳細全文を読む スポンサード リンク
|